package com.gthncz;

import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;

public class MeituanDemo2 {


    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[][] wills = new int[n][n];

        for (int i=0; i<n; ++i) {
            for (int j=0; j<n; ++j) {
                wills[i][j] = sc.nextInt();
            }
        }

        // result
        int[] res = new int[n];
        for (int i=0; i<n; ++i) res[i] = -1;

        for (int i=0; i<n; ++i) { // person
            for (int j=0; j<n; ++j) { // will idx
                int will = wills[i][j] - 1;
                if (res[will] == -1) {
                    res[will] = i;
                    break;
                }
            }
        }

        HashMap<Integer, Integer> map = new HashMap<>(n);
        for (int i=0; i<n; ++i) {
            map.put(res[i], i + 1);
        }

        boolean isStart = true;
        for (int i=0; i<n; ++i) {
            if (isStart) {
                isStart = false;
                System.out.printf("%d", map.get(i));
            } else {
                System.out.printf(" %d", map.get(i));
            }
        }
    }

}
